import QtQuick 2.0
import QtQuick.Layouts 1.1
import QtQuick.Controls 1.4
Rectangle {
    anchors.fill: parent
    property int offset: 50
    property int spacing :10
    property alias display1: displayLeftarea
    Rectangle{
        id:displayLeftarea
        width: parent.width * 2/5
        height: parent.height
        color:"green"

        Text{
            id:text
            x:offset;y:offset
            text:"SPD"
            font.bold: true
            color:"white"
            font.pointSize: 18
        }
        LCDNumber{
            id:lcdNumber1
            x:offset
            y:offset + text.height + spacing
            lcdNum: 1234
        }
        CustomIndicatorLight{
            x:offset + lcdNumber1.lcdtext.contentWidth + spacing
            y:offset + text.height + spacing*2
        }
        Text{
            id:text1
            x:offset + 300
            y:offset
            text:"HDG"
            font.bold: true
            color:"white"
            font.pointSize: 18
        }
        LCDNumber{
            id:lcdNumber2
            x:offset + 300
            y:offset + text.height + spacing
            lcdNum: 456
        }
        Text{
            id:text2
            x:offset + 300 + lcdNumber2.lcdtext.contentWidth + spacing
            y:offset
            text:"LAT"
            font.bold: true
            color:"white"
            font.pointSize: 18
        }
        CustomIndicatorLight{
            id:light0
            x:offset + 300 + lcdNumber2.lcdtext.contentWidth + spacing
            y:offset + text1.height + spacing*2
        }
    }
    Rectangle{
        id:displayMidarea
        anchors.left: displayLeftarea.right
        width: parent.width * 1/5
        height: parent.height
        color:"green"
        Text{
            anchors.centerIn: parent
            color:"white"
            text:"HDG V/S"
            font.bold: true
            font.pointSize: 20
        }
    }
    Rectangle{
        id:displayRightarea
        anchors.left: displayMidarea.right
        width: parent.width * 2/5
        height: parent.height
        color:"green"
        Text{
            id:text3
            x:offset;y:offset
            text:"ALT"
            font.bold: true
            color:"white"
            font.pointSize: 18
        }
        LCDNumber{
            id:lcdNumber3
            x:offset
            y:offset + text3.height + spacing
            lcdNum: 1234
        }
        Text{
            id:text4
            x:parent.width /2 - text4.contentWidth /2
            y:offset
            text:"LVL/CH"
            font.bold: true
            color:"white"
            font.pointSize: 18
        }
        CustomIndicatorLight{
            id:light1s
            x:parent.width /2 - text4.contentWidth /2
            y:offset + text4.height + spacing*2
        }
        Text{
            id:text5
            color:"white"
            text:"V/S"
            x:parent.width - 2*offset - text5.contentWidth
            y:offset
            font.bold: true
            font.pointSize: 20
        }
        LCDNumber{
            id:lcdNumber4
            x:parent.width - 3*offset - text5.contentWidth
            y:offset + text5.height + spacing
            lcdNum: 9999
        }
    }
}

